<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');?>
<?php $this->load->view('common/head');?>

<?php $this->load->view('common/header');?>
<div class="main-container" id="main-container">
    <script type="text/javascript">
        try {
            ace.settings.check('main-container', 'fixed')
        } catch (e) {
        }
    </script>

    <?php $this->load->view('common/sidebar');?>
    <div class="main-content">
        <div class="main-content-inner">
            <!-- #section:basics/content.breadcrumbs -->
            <?php $this->load->view('common/breadcrumbs');?>

            <!-- /section:basics/content.breadcrumbs -->
            <div class="page-content">

                <?php $this->load->view('common/set');?>

                <!-- /section:settings.box -->
                <div class="row">
                <div class="cf">
                    <a class="btn btn-info pull-left" href="<?php echo site_url(X_URL.'article/cate_add') ?>" value="">新增</a>
                </div>
                   
                        <table class="table table-striped table-bordered">
                            <thead>
                            <tr>
                                <th class="center"><input class="check-all" type="checkbox" value=""></th>
                                <th>分类ID</th>
                                <th>分类名称</th>
                                <th>分类排序</th>
                                <th class="col-xs-7">操作</th>
                            </tr>
                            </thead>
                            <tbody>
                            <?php if($cates){?>
                            <?php foreach($cates as $v){?>
                            <tr>
                            <td class="center">
                                <input class="uids" type="checkbox" name="gids[]" value="<?php echo $v['id'];?>">
                            </td>
                            <td  class="col-sm-3"><?php echo $v['id'];?></td>
							<td  class="col-sm-3"><span class="label label-sm label-info arrowed arrowed-righ"><?php echo $v['category_name']; ?></span></td>
                            <td  class="col-sm-2"><?php echo $v['order'];?></td>
							<td  class="col-sm-3">
                                <a class="blue" href="<?php echo site_url(X_URL.'article/cate_edit/'.$v['id'])?>" title="编辑分类"><i class="ace-icon fa fa-plus-circle bigger-100"></i>编辑</a>
<!--                                <a class="red del" href="--><?php //echo site_url(X_URL.'article/cate_del/'.$v['id']);?><!--" title="删除分类"><i class="ace-icon fa fa-plus-circle bigger-100"></i>删除</a>-->
<!--                                </td>-->
                            </tr>
                            <?php } ?>
                            <?php } else {?>
                                <tr>
                                    <td colspan="4">无分类</td>
                                </tr>
                            <?php } ?>
                            </if>
                            </tbody>
                        </table>
<!--                        {$page}-->
                        <!-- PAGE CONTENT ENDS -->
                    <!-- /.col -->
                </div><!-- /.row -->
            </div><!-- /.page-content -->
        </div>
    </div><!-- /.main-content -->

<?php $this->load->view('common/footer');?>
</div><!-- /.main-container -->

<?php $this->load->view('common/footerjs');?>
<!-- inline scripts related to this page -->
<script type="text/javascript">
    $(function () {

        $("#officialnews ul").html('<div class="ace-icon fa fa-spinner fa-spin orange"></div>');

    })

</script>
</body>
</html>
